xi2: Normalize scroll deltas
authorMatthias Clasen <mclasen@redhat.com>
Mon, 5 Mar 2012 00:12:27 +0000 (19:12 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Mon, 5 Mar 2012 00:12:27 +0000 (19:12 -0500)
commit3dd5e88c07f659d66ee0f7305a96b51b7fe1072d
tree214c6a043dc1322e4fb469e03febba5873dbf1ab
parent47c190a1b732225a9c26bfd492f8c392f5adc931
xi2: Normalize scroll deltas

XI2 provides us with an increment for each scroll valuator,
and by dividing the delta by the increment, we obtain normalized
values in some abstract 'scroll unit'.

For mouse wheels, the evdev driver reports an increment of -1,
so doing this division fixes the inverted scrolling with wheels
that we've seen recently.
gdk/x11/gdkdevice-xi2.c
gdk/x11/gdkdevicemanager-xi2.c
gdk/x11/gdkprivate-x11.h